import { _delete, get, post, put } from '@/ck/plugin/axios'

class Campus {

  //查询校区列表
  static async getCampusS (CampusName, page = 0, Limit = 10) {
    return post('api/Manage/Campus/PageSearch', {
      CampusName,
      page,
      Limit
    })
  }
  //校区集合数据查询
  static async PageSearchList () {
    return post('api/Manage/Campus/PageSearchList')
  }
  static async create(data){
    return post('api/Manage/Campus/Add', data)
  }

  static async updata (data) {
    return post(`api/Manage/Campus/Update`, data)
  }
  static async updateStatus (ID,Status) {
    return post('api/Manage/Campus/UpdateStatus', {
      ID,
      Status
    })
  }
  static async setSortMethod (ID,Sort,Type) {
    return post('api/Manage/Campus/SetSortMethod', {
      ID,
      Sort,
      Type,//“Up”上移,”Down”下移,”Top”置顶
    })
  }

  static async getDetail (ID) {
    return post('api/Manage/Campus/SearchModelDetails', {
      ID
    })
  }

  static async delete (ID) {
    return post(`api/Manage/Campus/Delete`,{
      ID
    })
  }

}
export default Campus
